package com.kg.fiber;

import javax.servlet.Filter;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.core.Ordered;
import org.springframework.core.annotation.Order;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.web.filter.CharacterEncodingFilter;

@SpringBootApplication
@EnableScheduling
public class FibernodeApplication {

	public static void main(String[] args) {
		SpringApplication.run(FibernodeApplication.class, args);
	}
	
    @Order(Ordered.HIGHEST_PRECEDENCE)  
    @Bean  
    Filter characterEncodingFilter() {  
           CharacterEncodingFilter filter = new CharacterEncodingFilter();  
           filter.setEncoding("UTF-8");  
           filter.setForceEncoding(true);  
           return filter; 
    }
}
